<!-- HTML header for doxygen 1.8.3.1-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.3.1"/>
<title>Sifteo SDK: Sifteo::BG0Drawable Struct Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="doxygen-style-overrides.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<center>
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Sifteo SDK" src="sdk_logo.png"/></td>
  <td style="padding-left: 0.5em;">
   <div id="projectname">
   &#160;<span id="projectnumber">v1.0.0</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
</center>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.3.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Home</span></a></li>
      <li><a href="pages.html"><span>Guides</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li class="current"><a href="annotated.html"><span>Reference</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Groups</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark">&#160;</span>Pages</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><b>Sifteo</b></li><li class="navelem"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html">BG0Drawable</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pub-static-methods">Static Public Member Functions</a> &#124;
<a href="struct_sifteo_1_1_b_g0_drawable-members.html">List of all members</a>  </div>
  <div class="headertitle">
<div class="title">Sifteo::BG0Drawable Struct Reference<div class="ingroups"><a class="el" href="group__video.html">Video</a></div></div>  </div>
</div><!--header-->
<div class="contents">

<p>A VRAM accessor for drawing graphics in the BG0 mode.  
 <a href="struct_sifteo_1_1_b_g0_drawable.html#details">More...</a></p>

<p><code>#include &lt;<a class="el" href="bg0_8h_source.html">sifteo/video/bg0.h</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:aecf4d2078f27fac9eea1e00e1f56a7d0"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aecf4d2078f27fac9eea1e00e1f56a7d0"></a>
<a class="el" href="struct_sifteo_1_1_cube_i_d.html">CubeID</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#aecf4d2078f27fac9eea1e00e1f56a7d0">cube</a> () const </td></tr>
<tr class="memdesc:aecf4d2078f27fac9eea1e00e1f56a7d0"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the <a class="el" href="struct_sifteo_1_1_cube_i_d.html" title="A lightweight identifier for one Sifteo cube.">CubeID</a> associated with this drawable. <br/></td></tr>
<tr class="separator:aecf4d2078f27fac9eea1e00e1f56a7d0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4003943fbd4f676a18357e2756065c1f"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a4003943fbd4f676a18357e2756065c1f"></a>
void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a4003943fbd4f676a18357e2756065c1f">erase</a> (uint16_t index=0)</td></tr>
<tr class="memdesc:a4003943fbd4f676a18357e2756065c1f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Erase mode-specific VRAM, filling the BG0 buffer with the specified absolute tile index value and resetting the panning registers. <br/></td></tr>
<tr class="separator:a4003943fbd4f676a18357e2756065c1f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7ed61f90cbc51f15d28a6560754814f9"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a7ed61f90cbc51f15d28a6560754814f9"></a>
void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a7ed61f90cbc51f15d28a6560754814f9">erase</a> (const <a class="el" href="struct_sifteo_1_1_pinned_asset_image.html">PinnedAssetImage</a> &amp;<a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a45c677974532c67134adaac592c30400">image</a>)</td></tr>
<tr class="memdesc:a7ed61f90cbc51f15d28a6560754814f9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Erase mode-specific VRAM, filling the BG0 buffer with the first tile from the specified <a class="el" href="struct_sifteo_1_1_pinned_asset_image.html" title="An AssetImage in which all tiles are stored sequentially in memory.">PinnedAssetImage</a> and resetting the panning registers. <br/></td></tr>
<tr class="separator:a7ed61f90cbc51f15d28a6560754814f9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:abbdad115fa1975b04ac99e389836fe8a"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#abbdad115fa1975b04ac99e389836fe8a">fill</a> (<a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a> topLeft, <a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a> size, unsigned tileIndex)</td></tr>
<tr class="memdesc:abbdad115fa1975b04ac99e389836fe8a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Fill a rectangle of identical tiles, specified as a top-left corner location and a size.  <a href="#abbdad115fa1975b04ac99e389836fe8a">More...</a><br/></td></tr>
<tr class="separator:abbdad115fa1975b04ac99e389836fe8a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a783aeed11a9c424eaf619e440761f89a"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a783aeed11a9c424eaf619e440761f89a">fill</a> (<a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a> topLeft, <a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a> size, const <a class="el" href="struct_sifteo_1_1_pinned_asset_image.html">PinnedAssetImage</a> &amp;<a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a45c677974532c67134adaac592c30400">image</a>)</td></tr>
<tr class="memdesc:a783aeed11a9c424eaf619e440761f89a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Fill a rectangle of identical tiles, using the first tile of a pinned asset.  <a href="#a783aeed11a9c424eaf619e440761f89a">More...</a><br/></td></tr>
<tr class="separator:a783aeed11a9c424eaf619e440761f89a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a420e10c135fe151bb2900fea2fdaf365"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a420e10c135fe151bb2900fea2fdaf365"></a>
<a class="el" href="group__math.html#ga4aa5e1c76d3adebd72a73a7051ad1fe0">Int2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a420e10c135fe151bb2900fea2fdaf365">getPanning</a> () const </td></tr>
<tr class="memdesc:a420e10c135fe151bb2900fea2fdaf365"><td class="mdescLeft">&#160;</td><td class="mdescRight">Retrieve the last value set by <a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a7eaadfe5edf9b54df0e8aa3236124301" title="Change the hardware pixel-panning origin for this mode.">setPanning()</a>, modulo the layer size in pixels. <br/></td></tr>
<tr class="separator:a420e10c135fe151bb2900fea2fdaf365"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a45c677974532c67134adaac592c30400"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a45c677974532c67134adaac592c30400">image</a> (<a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a> pos, const <a class="el" href="struct_sifteo_1_1_asset_image.html">AssetImage</a> &amp;image, unsigned frame=0)</td></tr>
<tr class="memdesc:a45c677974532c67134adaac592c30400"><td class="mdescLeft">&#160;</td><td class="mdescRight">Draw a full <a class="el" href="struct_sifteo_1_1_asset_image.html" title="Any kind of asset image, as defined in your stir script.">AssetImage</a> frame, with its top-left corner at the specified location.  <a href="#a45c677974532c67134adaac592c30400">More...</a><br/></td></tr>
<tr class="separator:a45c677974532c67134adaac592c30400"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a218da39dbe08ed8707525a397d0ea4b6"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a218da39dbe08ed8707525a397d0ea4b6">image</a> (<a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a> destXY, <a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a> size, const <a class="el" href="struct_sifteo_1_1_asset_image.html">AssetImage</a> &amp;image, <a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a> srcXY, unsigned frame=0)</td></tr>
<tr class="memdesc:a218da39dbe08ed8707525a397d0ea4b6"><td class="mdescLeft">&#160;</td><td class="mdescRight">Draw part of an <a class="el" href="struct_sifteo_1_1_asset_image.html" title="Any kind of asset image, as defined in your stir script.">AssetImage</a> frame, with its top-left corner at the specified location.  <a href="#a218da39dbe08ed8707525a397d0ea4b6">More...</a><br/></td></tr>
<tr class="separator:a218da39dbe08ed8707525a397d0ea4b6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2c3bce719fa27408d51b3c4d72e65f0d"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a2c3bce719fa27408d51b3c4d72e65f0d">plot</a> (<a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a> pos, uint16_t tileIndex)</td></tr>
<tr class="memdesc:a2c3bce719fa27408d51b3c4d72e65f0d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Plot a single tile, by absolute tile index, at location 'pos' in tile units.  <a href="#a2c3bce719fa27408d51b3c4d72e65f0d">More...</a><br/></td></tr>
<tr class="separator:a2c3bce719fa27408d51b3c4d72e65f0d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7eaadfe5edf9b54df0e8aa3236124301"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a7eaadfe5edf9b54df0e8aa3236124301">setPanning</a> (<a class="el" href="group__math.html#ga4aa5e1c76d3adebd72a73a7051ad1fe0">Int2</a> pixels)</td></tr>
<tr class="memdesc:a7eaadfe5edf9b54df0e8aa3236124301"><td class="mdescLeft">&#160;</td><td class="mdescRight">Change the hardware pixel-panning origin for this mode.  <a href="#a7eaadfe5edf9b54df0e8aa3236124301">More...</a><br/></td></tr>
<tr class="separator:a7eaadfe5edf9b54df0e8aa3236124301"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4a84b4c8e262e1133b11b983eabbda52"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a4a84b4c8e262e1133b11b983eabbda52">span</a> (<a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a> pos, unsigned width, unsigned tileIndex)</td></tr>
<tr class="memdesc:a4a84b4c8e262e1133b11b983eabbda52"><td class="mdescLeft">&#160;</td><td class="mdescRight">Plot a horizontal span of tiles, by absolute tile index, given the position of the leftmost tile and the number of tiles to plot.  <a href="#a4a84b4c8e262e1133b11b983eabbda52">More...</a><br/></td></tr>
<tr class="separator:a4a84b4c8e262e1133b11b983eabbda52"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac47f76f61636efb162e6319a061b5176"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#ac47f76f61636efb162e6319a061b5176">span</a> (<a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a> pos, unsigned width, const <a class="el" href="struct_sifteo_1_1_pinned_asset_image.html">PinnedAssetImage</a> &amp;<a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a45c677974532c67134adaac592c30400">image</a>)</td></tr>
<tr class="memdesc:ac47f76f61636efb162e6319a061b5176"><td class="mdescLeft">&#160;</td><td class="mdescRight">Plot a horizontal span of tiles, using the first tile of a pinned asset.  <a href="#ac47f76f61636efb162e6319a061b5176">More...</a><br/></td></tr>
<tr class="separator:ac47f76f61636efb162e6319a061b5176"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac903664c81012a6acbaa6da9f3dc13a7"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#ac903664c81012a6acbaa6da9f3dc13a7">text</a> (<a class="el" href="group__math.html#ga4aa5e1c76d3adebd72a73a7051ad1fe0">Int2</a> topLeft, const <a class="el" href="struct_sifteo_1_1_asset_image.html">AssetImage</a> &amp;font, const char *str, char firstChar= ' ')</td></tr>
<tr class="memdesc:ac903664c81012a6acbaa6da9f3dc13a7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Draw text, using an <a class="el" href="struct_sifteo_1_1_asset_image.html" title="Any kind of asset image, as defined in your stir script.">AssetImage</a> as a fixed width font.  <a href="#ac903664c81012a6acbaa6da9f3dc13a7">More...</a><br/></td></tr>
<tr class="separator:ac903664c81012a6acbaa6da9f3dc13a7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a56b2561f10f8f0814d849b8e19581925"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a56b2561f10f8f0814d849b8e19581925"></a>
uint16_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a56b2561f10f8f0814d849b8e19581925">tile</a> (<a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a> pos)</td></tr>
<tr class="memdesc:a56b2561f10f8f0814d849b8e19581925"><td class="mdescLeft">&#160;</td><td class="mdescRight">Retrieve the absolute tile index currently set at the given address. The inverse of <a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a2c3bce719fa27408d51b3c4d72e65f0d" title="Plot a single tile, by absolute tile index, at location &#39;pos&#39; in tile units.">plot()</a>. <br/></td></tr>
<tr class="separator:a56b2561f10f8f0814d849b8e19581925"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab37e06fa2f57ad4bcd36d7eaa5f190e1"><td class="memItemLeft" align="right" valign="top">uint16_t&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#ab37e06fa2f57ad4bcd36d7eaa5f190e1">tileAddr</a> (<a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a> pos)</td></tr>
<tr class="memdesc:ab37e06fa2f57ad4bcd36d7eaa5f190e1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Calculate the video buffer address of a particular tile.  <a href="#ab37e06fa2f57ad4bcd36d7eaa5f190e1">More...</a><br/></td></tr>
<tr class="separator:ab37e06fa2f57ad4bcd36d7eaa5f190e1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2bc1917e71c235fc33f7956aaecec34f"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a2bc1917e71c235fc33f7956aaecec34f"></a>
_SYSVideoBuffer &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a2bc1917e71c235fc33f7956aaecec34f">videoBuffer</a> ()</td></tr>
<tr class="memdesc:a2bc1917e71c235fc33f7956aaecec34f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the <a class="el" href="struct_sifteo_1_1_video_buffer.html" title="A memory buffer which holds graphics data.">VideoBuffer</a> associated with this drawable. <br/></td></tr>
<tr class="separator:a2bc1917e71c235fc33f7956aaecec34f"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-static-methods"></a>
Static Public Member Functions</h2></td></tr>
<tr class="memitem:aad1e0f1d9cd67ff69dcb543b226eac0e"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="aad1e0f1d9cd67ff69dcb543b226eac0e"></a>
static unsigned&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#aad1e0f1d9cd67ff69dcb543b226eac0e">pixelHeight</a> ()</td></tr>
<tr class="memdesc:aad1e0f1d9cd67ff69dcb543b226eac0e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the height, in pixel, of this mode. <br/></td></tr>
<tr class="separator:aad1e0f1d9cd67ff69dcb543b226eac0e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a134ceff3ab128f9eafe05b1652e6a320"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a134ceff3ab128f9eafe05b1652e6a320"></a>
static <a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a134ceff3ab128f9eafe05b1652e6a320">pixelSize</a> ()</td></tr>
<tr class="memdesc:a134ceff3ab128f9eafe05b1652e6a320"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the size of this mode as a vector, in pixels. <br/></td></tr>
<tr class="separator:a134ceff3ab128f9eafe05b1652e6a320"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a23140c3f2baf3a2e12b333b2973d3961"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a23140c3f2baf3a2e12b333b2973d3961"></a>
static unsigned&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a23140c3f2baf3a2e12b333b2973d3961">pixelWidth</a> ()</td></tr>
<tr class="memdesc:a23140c3f2baf3a2e12b333b2973d3961"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the width, in pixels, of this mode. <br/></td></tr>
<tr class="separator:a23140c3f2baf3a2e12b333b2973d3961"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac90cf68725ce5516a72a7bd40fa2d4f8"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ac90cf68725ce5516a72a7bd40fa2d4f8"></a>
static unsigned&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#ac90cf68725ce5516a72a7bd40fa2d4f8">sizeInBytes</a> ()</td></tr>
<tr class="memdesc:ac90cf68725ce5516a72a7bd40fa2d4f8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the size of this drawable's tile data, in bytes. <br/></td></tr>
<tr class="separator:ac90cf68725ce5516a72a7bd40fa2d4f8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9d689918f64e9cffcb10f73370b11a65"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a9d689918f64e9cffcb10f73370b11a65"></a>
static unsigned&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a9d689918f64e9cffcb10f73370b11a65">sizeInWords</a> ()</td></tr>
<tr class="memdesc:a9d689918f64e9cffcb10f73370b11a65"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the size of this drawable's tile data, in 16-bit words. <br/></td></tr>
<tr class="separator:a9d689918f64e9cffcb10f73370b11a65"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4ad9bc26a37f9d946d28c7e2002777a4"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a4ad9bc26a37f9d946d28c7e2002777a4"></a>
static unsigned&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a4ad9bc26a37f9d946d28c7e2002777a4">tileHeight</a> ()</td></tr>
<tr class="memdesc:a4ad9bc26a37f9d946d28c7e2002777a4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the height, in tiles, of this mode. <br/></td></tr>
<tr class="separator:a4ad9bc26a37f9d946d28c7e2002777a4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:abad2a06283e40e514956918345c1a538"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="abad2a06283e40e514956918345c1a538"></a>
static <a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#abad2a06283e40e514956918345c1a538">tileSize</a> ()</td></tr>
<tr class="memdesc:abad2a06283e40e514956918345c1a538"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the size of this mode as a vector, in tiles. <br/></td></tr>
<tr class="separator:abad2a06283e40e514956918345c1a538"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0b4a2142f34528cb8bf0083af11a4097"><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a0b4a2142f34528cb8bf0083af11a4097"></a>
static unsigned&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="struct_sifteo_1_1_b_g0_drawable.html#a0b4a2142f34528cb8bf0083af11a4097">tileWidth</a> ()</td></tr>
<tr class="memdesc:a0b4a2142f34528cb8bf0083af11a4097"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the width, in tiles, of this mode. <br/></td></tr>
<tr class="separator:a0b4a2142f34528cb8bf0083af11a4097"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>A VRAM accessor for drawing graphics in the BG0 mode. </p>
<p>We have an 18x18 tile grid, which wraps around in both axes. </p>
</div><h2 class="groupheader">Member Function Documentation</h2>
<a class="anchor" id="abbdad115fa1975b04ac99e389836fe8a"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Sifteo::BG0Drawable::fill </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td>
          <td class="paramname"><em>topLeft</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td>
          <td class="paramname"><em>size</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned&#160;</td>
          <td class="paramname"><em>tileIndex</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Fill a rectangle of identical tiles, specified as a top-left corner location and a size. </p>
<p>All coordinates must be in range. This function performs no clipping. </p>

</div>
</div>
<a class="anchor" id="a783aeed11a9c424eaf619e440761f89a"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Sifteo::BG0Drawable::fill </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td>
          <td class="paramname"><em>topLeft</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td>
          <td class="paramname"><em>size</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="struct_sifteo_1_1_pinned_asset_image.html">PinnedAssetImage</a> &amp;&#160;</td>
          <td class="paramname"><em>image</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Fill a rectangle of identical tiles, using the first tile of a pinned asset. </p>
<p>All coordinates must be in range. This function performs no clipping. </p>

</div>
</div>
<a class="anchor" id="a45c677974532c67134adaac592c30400"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Sifteo::BG0Drawable::image </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td>
          <td class="paramname"><em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="struct_sifteo_1_1_asset_image.html">AssetImage</a> &amp;&#160;</td>
          <td class="paramname"><em>image</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned&#160;</td>
          <td class="paramname"><em>frame</em> = <code>0</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Draw a full <a class="el" href="struct_sifteo_1_1_asset_image.html" title="Any kind of asset image, as defined in your stir script.">AssetImage</a> frame, with its top-left corner at the specified location. </p>
<p>Locations are specified in tile units, relative to the top-left of the 18x18 grid.</p>
<p>All coordinates must be in range. This function performs no clipping. </p>

</div>
</div>
<a class="anchor" id="a218da39dbe08ed8707525a397d0ea4b6"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Sifteo::BG0Drawable::image </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td>
          <td class="paramname"><em>destXY</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td>
          <td class="paramname"><em>size</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="struct_sifteo_1_1_asset_image.html">AssetImage</a> &amp;&#160;</td>
          <td class="paramname"><em>image</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype"><a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td>
          <td class="paramname"><em>srcXY</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned&#160;</td>
          <td class="paramname"><em>frame</em> = <code>0</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Draw part of an <a class="el" href="struct_sifteo_1_1_asset_image.html" title="Any kind of asset image, as defined in your stir script.">AssetImage</a> frame, with its top-left corner at the specified location. </p>
<p>Locations are specified in tile units, relative to the top-left of the 18x18 grid.</p>
<p>All coordinates must be in range. This function performs no clipping. </p>

</div>
</div>
<a class="anchor" id="a2c3bce719fa27408d51b3c4d72e65f0d"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Sifteo::BG0Drawable::plot </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td>
          <td class="paramname"><em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">uint16_t&#160;</td>
          <td class="paramname"><em>tileIndex</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Plot a single tile, by absolute tile index, at location 'pos' in tile units. </p>
<p>All coordinates must be in range. This function performs no clipping. </p>

</div>
</div>
<a class="anchor" id="a7eaadfe5edf9b54df0e8aa3236124301"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Sifteo::BG0Drawable::setPanning </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__math.html#ga4aa5e1c76d3adebd72a73a7051ad1fe0">Int2</a>&#160;</td>
          <td class="paramname"><em>pixels</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Change the hardware pixel-panning origin for this mode. </p>
<p>The supplied vector is interpreted as the location on the tile buffer, in pixels, where the origin of the LCD will begin.</p>
<p>BG0 is an 18x18 buffer that wraps around in both directions. </p>

</div>
</div>
<a class="anchor" id="a4a84b4c8e262e1133b11b983eabbda52"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Sifteo::BG0Drawable::span </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td>
          <td class="paramname"><em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned&#160;</td>
          <td class="paramname"><em>tileIndex</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Plot a horizontal span of tiles, by absolute tile index, given the position of the leftmost tile and the number of tiles to plot. </p>
<p>All coordinates must be in range. This function performs no clipping. </p>

</div>
</div>
<a class="anchor" id="ac47f76f61636efb162e6319a061b5176"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Sifteo::BG0Drawable::span </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td>
          <td class="paramname"><em>pos</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">unsigned&#160;</td>
          <td class="paramname"><em>width</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="struct_sifteo_1_1_pinned_asset_image.html">PinnedAssetImage</a> &amp;&#160;</td>
          <td class="paramname"><em>image</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Plot a horizontal span of tiles, using the first tile of a pinned asset. </p>
<p>All coordinates must be in range. This function performs no clipping. </p>

</div>
</div>
<a class="anchor" id="ac903664c81012a6acbaa6da9f3dc13a7"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">void Sifteo::BG0Drawable::text </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__math.html#ga4aa5e1c76d3adebd72a73a7051ad1fe0">Int2</a>&#160;</td>
          <td class="paramname"><em>topLeft</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const <a class="el" href="struct_sifteo_1_1_asset_image.html">AssetImage</a> &amp;&#160;</td>
          <td class="paramname"><em>font</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const char *&#160;</td>
          <td class="paramname"><em>str</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">char&#160;</td>
          <td class="paramname"><em>firstChar</em> = <code>'&#160;'</code>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Draw text, using an <a class="el" href="struct_sifteo_1_1_asset_image.html" title="Any kind of asset image, as defined in your stir script.">AssetImage</a> as a fixed width font. </p>
<p>Each character is represented by a consecutive 'frame' in the image. Characters not present in the font will be skipped. </p>

</div>
</div>
<a class="anchor" id="ab37e06fa2f57ad4bcd36d7eaa5f190e1"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">uint16_t Sifteo::BG0Drawable::tileAddr </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="group__math.html#ga2e4fcb4037bc16967e23c20126d25396">UInt2</a>&#160;</td>
          <td class="paramname"><em>pos</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Calculate the video buffer address of a particular tile. </p>
<p>All coordinates must be in range. This function performs no clipping. </p>

</div>
</div>
<hr/>The documentation for this struct was generated from the following file:<ul>
<li><a class="el" href="bg0_8h_source.html">bg0.h</a></li>
</ul>
</div><!-- contents -->
<!-- HTML footer for doxygen 1.8.3.1-->
<!-- start footer part -->
    <hr class="footer"/>
    <address class="footer">
        <p><a href="http://sifteo.com">Sifteo</a> SDK v1.0.0 <small>(see <a href="https://developers.sifteo.com/sifteosdk">all versions</a>)</small></p>
        <p>Last updated Wed Mar 27 2013, by <a href="http://www.stack.nl/~dimitri/doxygen">Doxygen</a></p>
    </address>
</body>
</html>
